package com.homwork.ListIterator在List中源码解析;

import java.util.ArrayList;
import java.util.ListIterator;

public class Test2 {
    public static void main(String[] args) {
        ArrayList<Object> list = new ArrayList<>();
        list.add("haha");
        ListIterator<Object> it = list.listIterator();
        /***
         *  1.在ArrayList中重写了该父类的方法，创建了ListItr
         *    public ListIterator<E> listIterator() {
         *         return new ListItr(0);
         *     }
         *  2.跳转到
         *    public V get(Object key) {
         *         Node<K,V> e;
         *         return (e = getNode(hash(key), key)) == null ? null : e.value;
         *     }
         *
         *
         *
         *
         *
         *
         *
         *
         *
         *
         */
    }
}
